package com.fire.market.order.api.request;

import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;

import javax.validation.constraints.NotNull;

@Data
@ApiModel("订单创建参数")
public class OrderCreateParam {
    @ApiModelProperty(value = "用户id")
    @NotNull(message = "用户id不能为空")
    private Integer userId;

    @ApiModelProperty(value = "订单id")
    @NotNull(message = "订单id不能为空")
    private Integer itemId;

    @ApiModelProperty(value = "商品数量")
    @NotNull(message = "商品数量")
    private Integer amount;

    //若非空，则表示是以秒杀商品方式下单
    @ApiModelProperty(value = "若非空，则表示是以秒杀商品方式下单")
    private Integer promoId;

    // 防刷令牌
    @ApiModelProperty(value = "防刷令牌")
    private String promoToken;

    //验证码
    @ApiModelProperty(value = "验证码")
    private String verifyCode;

}
